package com.rosense.module.app.entity;

import java.sql.Clob;
import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;

/**
 * 帖子
 * @author 李岩飞
 * @email eliyanfei@126.com	
 * 2015年8月29日 下午1:36:15
 *
 */
@Table(name = "simple_bbs")
@Entity
public class BbsEntity {
	private String title;//标题
	private Clob content;//发送内容
	private String userId;//发送者
	private Date createDate;//发送时间
	private Date updateDate;
	private int remarks;//评论
	private int views;//访问
	private int zans;//点赞
	private int floor = 1;//楼层
	private String userName;
	private String id;
	private boolean recommend;
	
	public void setRecommend(boolean recommend) {
		this.recommend = recommend;
	}
	
	public boolean isRecommend() {
		return recommend;
	}

	@Column(length = 64)
	@Id
	public String getId() {
		return id;
	}

	public void setId(String id) {
		this.id = id;
	}

	public void setUpdateDate(Date updateDate) {
		this.updateDate = updateDate;
	}

	public Date getUpdateDate() {
		return updateDate;
	}

	public void setUserName(String userName) {
		this.userName = userName;
	}

	@Column(length = 64)
	public String getUserName() {
		return userName;
	}

	public void setFloor(int floor) {
		this.floor = floor;
	}

	public int getFloor() {
		return floor;
	}

	public void setZans(int zans) {
		this.zans = zans;
	}

	public int getZans() {
		return zans;
	}

	public void setViews(int views) {
		this.views = views;
	}

	public int getViews() {
		return views;
	}

	public void setRemarks(int remarks) {
		this.remarks = remarks;
	}

	public int getRemarks() {
		return remarks;
	}

	public BbsEntity() {
		this.createDate = new Date();
		this.updateDate = new Date();
	}

	@Column(length = 128)
	public String getTitle() {
		return title;
	}

	public void setTitle(String title) {
		this.title = title;
	}

	public Clob getContent() {
		return content;
	}

	public void setContent(Clob content) {
		this.content = content;
	}

	@Column(length = 64)
	public String getUserId() {
		return userId;
	}

	public void setUserId(String userId) {
		this.userId = userId;
	}

	public Date getCreateDate() {
		return createDate;
	}

	public void setCreateDate(Date createDate) {
		this.createDate = createDate;
	}

}
